package Main;

import Interface.pinmain;
import MiniSpanTree.MinMain;
import SeqList.Sqmain;
import ShortestPath_D.ShortesDmain;
import ShortestPath_F.ShortestPathmain;

import java.util.Scanner;

public class Main {


    public static void main(String[] args)throws Exception{
        Scanner sc = new Scanner(System.in);
        int M;
        System.out.println("*************欢迎使用城市通信网络建设系统理系统*************");
        System.out.println("\t1.城市名称、通信网络图（文本形式）及各城市间的权值");
        System.out.println("\t2.最小生成树(Prim算法)");
        System.out.println("\t3.城市名称、通信网络图（图形形式）及各城市间的权值");
        System.out.println("\t4.各城市间的最短路径和维修中心的合理修建方案");
        System.out.println("\t5.维修队到各城市的最短路径和最短距离");
        System.out.println("\t6.关闭程序。");
        while(true){
            System.out.println("请选择你要实现的功能序号（1/2/3/4/5/6）:");
            M=sc.nextInt();
            switch (M){
                case 1:
                    Sqmain.main(new String[1]);
                    break;
                case 2:
                    MinMain.main(new String[1]);
                    break;
                case 3:
                    pinmain.main(new String[1]);
                    break;
                case 4:
                    ShortestPathmain.main(new String[1]);
                    break;
                case 5:
                    ShortesDmain.main(new String[1]);
                    break;
                case 6:
                    System.out.println("程序结束");
                    System.exit(0);
                default:
                    System.out.println("请输入正确的序号！");
                    break;



            }

        }
    }
}
